
using Core.Toolkit.Core.Entitys;
using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;

namespace Core.SimpleTemp.Entitys
{

    public class SysArea : Entity
    {
        /// <summary>
        /// 父级ID
        /// </summary>
        public Guid? ParentId { get; set; }
        /// <summary>
        /// 区域代码
        /// </summary>
        [StringLength(50)]
        public String Code { get; set; }
        /// <summary>
        /// 区域名称
        /// </summary>
        [StringLength(100)]
        public String Name { get; set; }
        /// <summary>
        /// 备注
        /// </summary>
        public String Remark { get; set; }
        /// <summary>
        /// 隶属工厂
        /// </summary>
        public Guid? SubFactory { get; set; }
        public int? Sort { get; set; }
        [StringLength(20)]
        public String Type { get; set; }
        public int? Arc_R { get; set; }
        public ICollection<SysAreaPoint> SysAreaPoint { get; set; }

        public ICollection<SysJobPlace> SysJobPlace { get; set; } 
        
        //ALTER TABLE SysArea ADD LeadDutyID uniqueidentifier NULL
        /// <summary>
        /// 负责岗位ID
        /// </summary>
        public Guid? LeadDutyID { get; set; }

        /// <summary>
        /// 区域对应的部门id
        /// 说明：数据库字段不知道谁加的，实体没加，所以我加一下
        /// </summary>
        public Guid? SysDepartmentID { get; set; }
    }
}
